package com.lgx.authorize.module.service;

import java.sql.Date;
import java.util.List;

import com.lgx.authorize.module.entity.ApplicationApplykeyInfo;

/**
 * this is out service interface
 * @author pengdeyi (king)
 *
 */
public interface IApplicationApplykeyInfoService {
	/**
	 * time type for search,in interface so static int.---for apply time
	 */
	static final int APPLICATION_TIME_TYPE_APPLYTIME = 1;
	/**
	 * time type for search,in interface so static int ---for disable time
	 */
	static final int APPLICATION_TIME_TYPE_DISABLETIME = 2;
	
	/**
	 * time type for search,in interface so static int ----for refresh time
	 */
	static final int APPLICATION_TIME_TYPE_REFRESHTIME = 3;
	/**
	 * create
	 * @param applicationApplykeyInfo
	 */
	void createApplicationApplykeyInfo(ApplicationApplykeyInfo applicationApplykeyInfo);
	/**
	 * update
	 * @param applicationApplykeyInfo
	 */
	void updateApplicationApplykeyInfo(ApplicationApplykeyInfo applicationApplykeyInfo);
	/**
	 * delete
	 * @param applicationApplykeyInfo
	 */
	void deleteApplicationApplykeyInfo(ApplicationApplykeyInfo applicationApplykeyInfo);
	/**
	 * find by systemid
	 * @param systemid
	 * @return
	 */
	ApplicationApplykeyInfo findApplicationApplykeyInfoBySystemid(int systemid);
	/**
	 * list all
	 * @return
	 */
	List<ApplicationApplykeyInfo> listAllApplicationApplykeyInfos();
	
	/**
	 * find application apply info by application name
	 * @param appName
	 * @return
	 */
	ApplicationApplykeyInfo findApplicationApplyKeyInfoByName(String appName);
	
	/**
	 * find application apply info by application name and apply key
	 * @param appName
	 * @param key
	 * @return
	 */
	ApplicationApplykeyInfo findApplicationApplykeyInfoByNameKey(String appName,String key);
	
	/**
	 * list by time type
	 * @param startTime
	 * @param endTime
	 * @param timeType
	 * @return
	 */
	List<ApplicationApplykeyInfo> listApplicationApplykeyInfosByDate(Date startTime,Date endTime,String timeType);
	
	
}
